﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using System.Data.Sql;
using System.Data.SqlClient;
using DAO;
using DTO;

namespace BUS
{
    public partial class KhachHang_BUS
    {
        KhachHang_DAO khachhang_dao;

        public bool insertKhachHang(KhachHang khachhang_dto)
        {
            khachhang_dao = new KhachHang_DAO();
            return khachhang_dao.insertKhachHang(khachhang_dto);
        }

        public bool updateKhachHang(KhachHang khachhang_dto)
        {
            khachhang_dao = new KhachHang_DAO();
            return khachhang_dao.updateKhachHang(khachhang_dto);
        }

        public DataTable getDanhSachKhachHang()
        {
            khachhang_dao = new KhachHang_DAO();
            DataTable dt = new DataTable();
            dt = khachhang_dao.getDanhSachKhachHang();
            return dt;
        }

        public DataTable getDanhSachKhachHangSearch(string cmnd)
        {
            khachhang_dao = new KhachHang_DAO();
            DataTable dt = new DataTable();
            dt = khachhang_dao.getDanhSachKhachHangSearch(cmnd);
            return dt;
        }
    }
}
